home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / cpp_libs / csim / source.lha / source / C++SIM / Head.h < prev    next >
C/C++ Source or Header  |  1993-06-14  |  636b  |  53 lines

  1. /*
  2.  * Copyright (C) 1993
  3.  *
  4.  * Department of Computing Science,
  5.  * The University,
  6.  * Newcastle upon Tyne,
  7.  * UK.
  8.  */
  9.  
  10.  
  11. /*
  12.  * This class essentially defines the linked list manager used by the SIMSET
  13.  * class in SIMULA.
  14.  */
  15.  
  16.  
  17. #ifndef HEAD_H_
  18. #define HEAD_H_
  19.  
  20. #ifndef COMMON_H_
  21. #include "common.h"
  22. #endif
  23.  
  24.  
  25. class Link;
  26.  
  27.  
  28. class Head
  29. {
  30. public:
  31.     Head ();
  32.     virtual ~Head ();
  33.     
  34.     Link* First () const;
  35.     Link* Last () const;
  36.     
  37.     void AddFirst (Link*);
  38.     void AddLast (Link*);
  39.  
  40.     long Cardinal () const;
  41.     boolean Empty () const;
  42.  
  43.     void Clear ();
  44.     
  45. private:
  46.     Link *first, *last;
  47. };
  48.  
  49.  
  50. #include "Head.n"
  51.  
  52. #endif
  53.